

const routers = [
    {
        path: '/',
        meta: {
            title: '首页'
        },
        component: (resolve) => require(['./views/index.vue'], resolve)
    },
    {
        path: '/login',
        meta: {
            title: '登录'
        },
        component: (resolve) => require(['./views/login.vue'], resolve)
    },
    {
        path: '/admin',
        meta: {title: '管理后台'},
        component: (resolve) => require(['./views/admin.vue'], resolve),
        children: [
            {
                path: '',
                component: (resolve) => require(['./views/admin/index.vue'], resolve)
            },
            {
                path: '/articles',
                component: (resolve) => require(['./views/admin/articles.vue'], resolve)
            },
            {
                path: '/article-new',
                component: (resolve) => require(['./views/admin/articleNew.vue'], resolve)
            }
        ]
    }
];
export default routers;